<ui:composition xmlns:ui="http://java.sun.com/jsf/facelets"
                template="/template.xhtml"
                xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:h="http://java.sun.com/jsf/html"
                  xmlns:f="http://java.sun.com/jsf/core"
                  xmlns:p="http://primefaces.org/ui">
    <ui:define name="content">

        <f:view>
            <h:form>
                <p:growl showDetail="true" showSummary="true" />
                <p:panel header="EDIT FAQ DETAILS">
                    <h:form>
                        <h1><h:outputText value="Create/Edit"/></h1>
                        <p:panelGrid columns="2" >
                            
                           
                            <h:outputLabel value="Question:(*)" for="question" />
                            <p:inputTextarea id="question" value="#{fAQBean.faq.question}" title="Question" required="true" requiredMessage="The Question field is required."
                                             style="width: 500px" rows="6"/>
                            <h:outputLabel value="Answer:(*)" for="answer" />
                            <p:inputTextarea id="answer" value="#{fAQBean.faq.answer}" title="Answer" required="true" requiredMessage="The Answer field is required."
                                             style="width: 500px" rows="6"/>
                           
                           
                            <h:outputLabel></h:outputLabel>
                            <h:outputLabel>
                                <p:commandButton value="Save" action="#{fAQBean.updateFAQ}" ajax="false"/>
                                <p:commandButton value="Cancel" action="NOEDITFAQ" ajax="false" immediate="true"/>
                            </h:outputLabel>
                            
                        </p:panelGrid>
                         Please enter value in field (*)
                    </h:form>

                </p:panel>
               
            </h:form>
          
        </f:view>

        
    </ui:define>
</ui:composition>



